// @ts-ignore
/* eslint-disable */
import request from '@/request'

/** addUser POST /api/authUser/add */
export async function addUserUsingPost(body: API.AuthUserAddDTO, options?: { [key: string]: any }) {
  return request<API.BaseResponseLong_>('/api/authUser/add', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** deleteUser POST /api/authUser/delete */
export async function deleteUserUsingPost(
  body: API.DeleteRequest,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>('/api/authUser/delete', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** 注册邮箱发送验证码 POST /api/authUser/email */
export async function sendEmailUsingPost(body: API.EmailRequest, options?: { [key: string]: any }) {
  return request<API.BaseResponse>('/api/authUser/email', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** getUserById GET /api/authUser/get */
export async function getUserByIdUsingGet(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getUserByIdUsingGETParams,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseAuthUser_>('/api/authUser/get', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  })
}

/** getLoginUser GET /api/authUser/get/login */
export async function getLoginUserUsingGet(options?: { [key: string]: any }) {
  return request<API.BaseResponseLoginAuthUserVO_>('/api/authUser/get/login', {
    method: 'GET',
    ...(options || {}),
  })
}

/** getUserVoById GET /api/authUser/get/vo */
export async function getUserVoByIdUsingGet(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getUserVoByIdUsingGETParams,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseAuthUserVO_>('/api/authUser/get/vo', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  })
}

/** listUserVoByPage POST /api/authUser/list/page/vo */
export async function listUserVoByPageUsingPost(
  body: API.AuthUserQueryDTO,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponsePageAuthUserVO_>('/api/authUser/list/page/vo', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** userLogin POST /api/authUser/login */
export async function userLoginUsingPost(
  body: API.AuthUserLoginDTO,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseLoginAuthUserVO_>('/api/authUser/login', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** userLogout POST /api/authUser/logout */
export async function userLogoutUsingPost(options?: { [key: string]: any }) {
  return request<API.BaseResponseBoolean_>('/api/authUser/logout', {
    method: 'POST',
    ...(options || {}),
  })
}

/** register POST /api/authUser/register */
export async function registerUsingPost(
  body: API.AuthUserRegisterDTO,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseLong_>('/api/authUser/register', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** updateUser POST /api/authUser/update */
export async function updateUserUsingPost(
  body: API.AuthUserUpdateDTO,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>('/api/authUser/update', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** updateEmail POST /api/authUser/update/email */
export async function updateEmailUsingPost(
  body: API.AuthUserUpdateEmailDTO,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>('/api/authUser/update/email', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** updateSelf POST /api/authUser/update/self */
export async function updateSelfUsingPost(
  body: API.AuthUserUpdateSelfDTO,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>('/api/authUser/update/self', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}

/** updateUserStatus POST /api/authUser/update/status */
export async function updateUserStatusUsingPost(
  body: API.AuthUserUpdateStatusDTO,
  options?: { [key: string]: any }
) {
  return request<API.BaseResponseBoolean_>('/api/authUser/update/status', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  })
}
